let t = require;
let  e = module
let  o =  e.exports;
 o.default =  e.exports;

                'use strict';
                console.log("start");
                var _n161,
                    i =
                    (this && this.__extends) ||
                    ((_n161 = function n(t, e) {
                            return (_n161 =
                                Object.setPrototypeOf ||
                                ({
                                        __proto__: []
                                    }
                                    instanceof Array &&
                                    function(t, e) {
                                        t.__proto__ = e;
                                    }) ||
                                function(t, e) {
                                    for (var o in e) {
                                        Object.prototype.hasOwnProperty.call(e, o) && (t[o] = e[o]);
                                    }
                                })(t, e);
                        }),
                        function(t, e) {
                            function o() {
                                this.constructor = t;
                            }
                            _n161(t, e),
                                (t.prototype =
                                    null === e ?
                                    Object.create(e) :
                                    ((o.prototype = e.prototype), new o()));
                        });
                Object.defineProperty(o, '__esModule', {
                        value: !0
                    }),
                    (o.StoreInfo = void 0);
                var r = t('AbsInfo'),
                    a = t('MathUtils'),
                    s = t('TimeMrg'),
                    c = t('DateTimeUtils'),
                    l = (function(t) {
                        function e() {
                            var e = t.call(this) || this;
                            return (
                                (e._time = c.DateTimeUtils.getZero(s.TimeMrg.serverTime)), e
                            );
                        }
                        return (
                            i(e, t),
                            (e.prototype.setData = function(t) {
                                t &&
                                    (this.init(t),
                                        (this._count = this.limitNum + this.free),
                                        (this._time = s.TimeMrg.serverTime),
                                        (this._itemCount = this.getCfgData('itemCount')),
                                        this.emit(r.InfoEvent.Changed));
                            }),
                            (e.prototype.update = function(t) {
                                void 0 === t && (t = 1),
                                    (this._itemCount =
                                        this.getCfgData('itemCount') +
                                        this.getCfgData('moneyAdd') * t),
                                    this.emit(r.InfoEvent.Changed);
                            }),
                            (e.prototype.resetTime = function() {
                                (this._time = s.TimeMrg.serverTime + 6e4 * this.boxRefreshTime),
                                this.emit(r.InfoEvent.Changed);
                            }),
                            (e.prototype.setExtra = function(t) {
                                (this._extra = t),
                                t &&
                                    ((this._count = t.count),
                                        (this._time = t.time),
                                        this.emit(r.InfoEvent.Changed));
                            }),
                            (e.prototype.nextTime = function() {
                                (this._time =
                                    s.TimeMrg.serverTime + 216e5 * this.boxRefreshTime),
                                this.emit(r.InfoEvent.Changed);
                            }),
                            Object.defineProperty(e.prototype, 'count', {
                                get: function get() {
                                    return this._count;
                                },
                                set: function set(t) {
                                    var e = a.default.clamp(t, 0, this.limitNum);
                                    this._count != e &&
                                        ((this._count = e), this.emit(r.InfoEvent.Changed));
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'time', {
                                get: function get() {
                                    return this._time;
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            (e.prototype.getJson = function() {
                                var t = {};
                                return (
                                    (t.id = this.id),
                                    (t.count = this.count),
                                    (t.time = this._time),
                                    t
                                );
                            }),
                            Object.defineProperty(e.prototype, 'id', {
                                get: function get() {
                                    return this.getCfgData('id');
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'name', {
                                get: function get() {
                                    return this.getCfgData('name');
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'type', {
                                get: function get() {
                                    return this.getCfgData('type');
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'kind', {
                                get: function get() {
                                    return this.getCfgData('kind');
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'icon', {
                                get: function get() {
                                    return this.getCfgData('icon');
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'background', {
                                get: function get() {
                                    return this.getCfgData('background');
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'discount', {
                                get: function get() {
                                    return this.getCfgData('discount');
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'free', {
                                get: function get() {
                                    return this.getCfgData('free');
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'priceType', {
                                get: function get() {
                                    return this.getCfgData('priceType');
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'price', {
                                get: function get() {
                                    return this.getCfgData('price');
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'limitNum', {
                                get: function get() {
                                    return this.getCfgData('limitNum');
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'itemId', {
                                get: function get() {
                                    return this.getCfgData('itemId');
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'itemCount', {
                                get: function get() {
                                    return this._itemCount;
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'boxRefreshTime', {
                                get: function get() {
                                    return this.getCfgData('boxRefreshTime');
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'moneyAdd', {
                                get: function get() {
                                    return this.getCfgData('moneyAdd');
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            Object.defineProperty(e.prototype, 'desc', {
                                get: function get() {
                                    return this.getCfgData('desc');
                                },
                                enumerable: !1,
                                configurable: !0
                            }),
                            e
                        );
                    })(r.default);
                (o.StoreInfo = l), console.log("end");
            module.exports =  e.exports;